<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>订单后台管理</title>
    <link rel="stylesheet" type="text/css" href="../../static/admin/css/reset.css">
    <link rel="stylesheet" type="text/css" href="../../static/admin/css/main.css">
    <script type="text/javascript" src="../../static/admin/js/jquery-1.12.4.min.js"></script>
    <script src="../../static/admin/tinymce/js/tinymce/tinymce.min.js"></script>
    <script src="../../static/admin/js/news_review_detail.js"></script>
    <link rel="stylesheet" href="../../static/admin/css/layui.css"  media="all">
</head>
<body>
<div class="breadcrub">
    当前位置：订单管理 > 订单录入
</div>
<div class="pannel">
    <form class="news_edit" action="/admin/add_order" method="post" enctype="multipart/form-data">
        <input type="hidden" name="csrf_token" value="{{ csrf_token() }}"/>
        <h3 class="review_title">订单录入</h3>
        <div class="form_group">
            <label>订单状态：</label>
            <select class="sel_opt" name="status_id" style="width:8%">
                <option value='1'>未下单</option>

            </select>
        </div>
        <div class="form_group" >
            <label>下单时间：</label>

       <div class="layui-input-inline" style="width:8%;">
        <input name="jiedan_time" type="text" class="layui-input" id="test1" placeholder="点击选择日期">
      </div>
    

        </div>
        <div class="form_group">
            <label>店铺名称：</label>
            <input name="shop_name" type="text" class="input_txt2">
        </div>
        <div class="form_group">
            <label>产品金额：</label>
            <input name="amount" type="text" class="input_txt2">
        </div>
        <div class="form_group">
            <label>关键词：</label>
            <input name="keywords" type="text" class="input_txt2">
        </div>
        <div class="form_group">
            <label>ASIN：</label>
            <input name="ASIN" type="text" class="input_txt2">
        </div>
        <div class="form_group">
            <label>客户类型：</label>
            <select class="sel_opt" name="seller_type" style="width:8%">
                <option value='2'>买家</option>
                <option value='1'>卖家</option>

            </select>
        </div>
        <div class="form_group">
            <label>站点：</label>
              <select class="sel_opt" name="site_id" style="width:8%">
                <option value='1'>US</option>
                <option value='2'>UK</option>
                <option value='3'>DE</option>
                <option value='4'>CA</option>
            </select>
        </div>
        <div class="form_group">
            <label>服务商：</label>
              <select class="sel_opt" name="offer_name" style="width:8%">
                  {% for offer in data%}
                <option >{{offer.nick_name}}</option>
                  {% endfor %}

            </select>
        </div>
        <div class="form_group">
            <label>订单数量：</label>
            <input name="order_num" type="text" class="input_txt2" value="1">
        </div>
        <div class="form_group">
            <label>备注：</label>
            <textarea name="ps" class="input_multxt" style="width: 20%;"></textarea>
        </div>

        <div class="form_group">
            <label>商品图片：</label>
            <input type="file" name="item_picture" class="input_file">
        </div>



        <div class="form_group indent_group line_top">
            <input type="submit" value="确定" class="confirm">
            <input type="button" value="取消" class="cancel" onclick="cancel()">
        </div>
        <!-- 隐藏字段，用于记录当前订单id -->

    </form>
</div>

<script>
    $(function () {
        var $radio = $('input[name="action"]');
        $radio.click(function () {
            if ($(this).index() == 1) {
                $('.group_hide').show();
            }
            else {
                $('.group_hide').hide();
            }
        });

        tinymce.init({
            //选择class为content的标签作为编辑器
            selector: '#rich_content',
            //方向从左到右
            directionality: 'ltr',
            //语言选择中文
            language: 'zh_CN',
            //高度为400
            height: 400,
            width: '100%',
            //按tab不换行
            nonbreaking_force_tab: true,
            readonly: 1
        });

    })
</script>

<script src="../../static/admin/js/layui.js" charset="utf-8"></script>
<script>
layui.use('laydate', function(){
  var laydate = layui.laydate;
 //常规用法
  laydate.render({
    elem: '#test1'
  });

  //国际版
  laydate.render({
    elem: '#test1-1'
    ,lang: 'en'
  });
  //日期时间选择器
  laydate.render({
    elem: '#test5'
    ,type: 'datetime'
  });

  //日期范围
  laydate.render({
    elem: '#test6'
    ,range: true
  });

  //年范围
  laydate.render({
    elem: '#test7'
    ,type: 'year'
    ,range: true
  });

  //年月范围
  laydate.render({
    elem: '#test8'
    ,type: 'month'
    ,range: true
  });

  //时间范围
  laydate.render({
    elem: '#test9'
    ,type: 'time'
    ,range: true
  });

  //日期时间范围
  laydate.render({
    elem: '#test10'
    ,type: 'datetime'
    ,range: true
  });

  //自定义格式
  laydate.render({
    elem: '#test11'
    ,format: 'yyyy年MM月dd日'
  });
  laydate.render({
    elem: '#test12'
    ,format: 'dd/MM/yyyy'
  });
  laydate.render({
    elem: '#test13'
    ,format: 'yyyyMMdd'
  });
  laydate.render({
    elem: '#test14'
    ,type: 'time'
    ,format: 'H点m分'
  });
  laydate.render({
    elem: '#test15'
    ,type: 'month'
    ,range: '~'
    ,format: 'yyyy-MM'
  });
  laydate.render({
    elem: '#test16'
    ,type: 'datetime'
    ,range: '到'
    ,format: 'yyyy年M月d日H时m分s秒'
  });

  //开启公历节日
  laydate.render({
    elem: '#test17'
    ,calendar: true
  });

  //自定义重要日
  laydate.render({
    elem: '#test18'
    ,mark: {
      '0-10-14': '生日'
      ,'0-12-31': '跨年' //每年的日期
      ,'0-0-10': '工资' //每月某天
      ,'0-0-15': '月中'
      ,'2017-8-15': '' //如果为空字符，则默认显示数字+徽章
      ,'2099-10-14': '呵呵'
    }
    ,done: function(value, date){
      if(date.year === 2017 && date.month === 8 && date.date === 15){ //点击2017年8月15日，弹出提示语
        layer.msg('这一天是：中国人民抗日战争胜利72周年');
      }
    }
  });

  //限定可选日期
  var ins22 = laydate.render({
    elem: '#test-limit1'
    ,min: '2016-10-14'
    ,max: '2080-10-14'
    ,ready: function(){
      ins22.hint('日期可选值设定在 <br> 2016-10-14 到 2080-10-14');
    }
  });

  //前后若干天可选，这里以7天为例
  laydate.render({
    elem: '#test-limit2'
    ,min: -7
    ,max: 7
  });

  //限定可选时间
  laydate.render({
    elem: '#test-limit3'
    ,type: 'time'
    ,min: '09:30:00'
    ,max: '17:30:00'
    ,btns: ['clear', 'confirm']
  });

  //同时绑定多个
  lay('.test-item').each(function(){
    laydate.render({
      elem: this
      ,trigger: 'click'
    });
  });

  //初始赋值
  laydate.render({
    elem: '#test19'
    ,value: '1989-10-14'
    ,isInitValue: true
  });

  //选中后的回调
  laydate.render({
    elem: '#test20'
    ,done: function(value, date){
      layer.alert('你选择的日期是：' + value + '<br>获得的对象是' + JSON.stringify(date));
    }
  });

  //日期切换的回调
  laydate.render({
    elem: '#test21'
    ,change: function(value, date){
      layer.msg('你选择的日期是：' + value + '<br><br>获得的对象是' + JSON.stringify(date));
    }
  });
  //不出现底部栏
  laydate.render({
    elem: '#test22'
    ,showBottom: false
  });

  //只出现确定按钮
  laydate.render({
    elem: '#test23'
    ,btns: ['confirm']
  });

  //自定义事件
  laydate.render({
    elem: '#test24'
    ,trigger: 'mousedown'
  });

  //点我触发
  laydate.render({
    elem: '#test25'
    ,eventElem: '#test25-1'
    ,trigger: 'click'
  });

  //双击我触发
  lay('#test26-1').on('dblclick', function(){
    laydate.render({
      elem: '#test26'
      ,show: true
      ,closeStop: '#test26-1'
    });
  });

  //日期只读
  laydate.render({
    elem: '#test27'
    ,trigger: 'click'
  });

  //非input元素
  laydate.render({
    elem: '#test28'
  });

  //墨绿主题
  laydate.render({
    elem: '#test29'
    ,theme: 'molv'
  });

  //自定义颜色
  laydate.render({
    elem: '#test30'
    ,theme: '#393D49'
  });

  //格子主题
  laydate.render({
    elem: '#test31'
    ,theme: 'grid'
  });


  //直接嵌套显示
  laydate.render({
    elem: '#test-n1'
    ,position: 'static'
  });
  laydate.render({
    elem: '#test-n2'
    ,position: 'static'
    ,lang: 'en'
  });
  laydate.render({
    elem: '#test-n3'
    ,type: 'month'
    ,position: 'static'
  });
  laydate.render({
    elem: '#test-n4'
    ,type: 'time'
    ,position: 'static'
  });
});
</script>
</body>
</html>